import request from '@/utils/request'

export function getAll() {
  return request({
    url: '/materials/mater/getAll',
    method: 'get',
  })
}

export function save(data) {
  return request({
    url: '/materials/mater/save',
    method: 'post',
    data: data
  })
}

// 修改菜品
export function updateCuisine(data) {
  return request({
    url: '/materials/mater/updateById',
    method: 'post',
    data: data
  })
}

export function deleteById(query) {
  return request({
    url: `/materials/mater/deleteById/${query}`,
    method: 'get',
    params: query
  })
}
